﻿@model GdHotel.Data.SideBlock

<div class="editor-label">
    @Html.LabelFor(model => model.Title)
</div>
<div class="editor-field">
    @Html.EditorFor(model => model.Title)
    @Html.ValidationMessageFor(model => model.Title)
</div>

<div class="editor-label">
    @Html.LabelFor(model => model.PicturePath)
</div>
@if (Model != null && !String.IsNullOrEmpty(Model.PicturePath))
{
    <div class="editor-label">
        Текущее изображение:<br />
        <img src="@Url.Content(Model.PicturePath)" alt="" />
    </div>
}
<div class="editor-field">
    <input type="file" id="file" name="file">
    @Html.ValidationMessageFor(model => model.PicturePath)
</div>

<div class="editor-label">
    @Html.LabelFor(model => model.Link)
</div>
<div class="editor-field">
    @Html.EditorFor(model => model.Link)
    @Html.ValidationMessageFor(model => model.Link)
</div>
